3.1270 \(\int \frac {x (a+b \tan ^{-1}(c x))^2}{(d+e x^2)^2} \, dx\)

Optimal. Leaf size=457 \[ \frac {c^2 \left (a+b \tan ^{-1}(c x)\right )^2}{2 e \left (c^2 d-e\right )}-\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{(1-i c x) \left (c \sqrt {-d}-i \sqrt {e}\right )}\right )}{2 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}+\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{(1-i c x) \left (c \sqrt {-d}+i \sqrt {e}\right )}\right )}{2 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (\frac {\sqrt {e} x}{\sqrt {-d}}+1\right )}+\frac {i b^2 c \text {Li}_2\left (1-\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{\left (c \sqrt {-d}-i \sqrt {e}\right ) (1-i c x)}\right )}{4 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}-\frac {i b^2 c \text {Li}_2\left (1-\frac {2 c \left (\sqrt {e} x+\sqrt {-d}\right )}{\left (\sqrt {-d} c+i \sqrt {e}\right ) (1-i c x)}\right )}{4 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )} \]

[Out]

1/2*c^2*(a+b*arctan(c*x))^2/(c^2*d-e)/e-1/2*b*c*(a+b*arctan(c*x))*ln(2*c*((-d)^(1/2)-x*e^(1/2))/(1-I*c*x)/(c*(
-d)^(1/2)-I*e^(1/2)))/(c^2*d-e)/(-d)^(1/2)/e^(1/2)+1/2*b*c*(a+b*arctan(c*x))*ln(2*c*((-d)^(1/2)+x*e^(1/2))/(1-
I*c*x)/(c*(-d)^(1/2)+I*e^(1/2)))/(c^2*d-e)/(-d)^(1/2)/e^(1/2)+1/4*I*b^2*c*polylog(2,1-2*c*((-d)^(1/2)-x*e^(1/2
))/(1-I*c*x)/(c*(-d)^(1/2)-I*e^(1/2)))/(c^2*d-e)/(-d)^(1/2)/e^(1/2)-1/4*I*b^2*c*polylog(2,1-2*c*((-d)^(1/2)+x*
e^(1/2))/(1-I*c*x)/(c*(-d)^(1/2)+I*e^(1/2)))/(c^2*d-e)/(-d)^(1/2)/e^(1/2)-1/4*(a+b*arctan(c*x))^2/d/e/(1-x*e^(
1/2)/(-d)^(1/2))-1/4*(a+b*arctan(c*x))^2/d/e/(1+x*e^(1/2)/(-d)^(1/2))

________________________________________________________________________________________

Rubi [A]  time = 1.09, antiderivative size = 457, normalized size of antiderivative = 1.00, number of steps used = 27, number of rules used = 10, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.476, Rules used = {4978, 4864, 4856, 2402, 2315, 2447, 4984, 4884, 4920, 4854} \[ \frac {i b^2 c \text {PolyLog}\left (2,1-\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{(1-i c x) \left (c \sqrt {-d}-i \sqrt {e}\right )}\right )}{4 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}-\frac {i b^2 c \text {PolyLog}\left (2,1-\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{(1-i c x) \left (c \sqrt {-d}+i \sqrt {e}\right )}\right )}{4 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}+\frac {c^2 \left (a+b \tan ^{-1}(c x)\right )^2}{2 e \left (c^2 d-e\right )}-\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{(1-i c x) \left (c \sqrt {-d}-i \sqrt {e}\right )}\right )}{2 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}+\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{(1-i c x) \left (c \sqrt {-d}+i \sqrt {e}\right )}\right )}{2 \sqrt {-d} \sqrt {e} \left (c^2 d-e\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (\frac {\sqrt {e} x}{\sqrt {-d}}+1\right )} \]

Antiderivative was successfully verified.

[In]

Int[(x*(a + b*ArcTan[c*x])^2)/(d + e*x^2)^2,x]

[Out]

(c^2*(a + b*ArcTan[c*x])^2)/(2*(c^2*d - e)*e) - (a + b*ArcTan[c*x])^2/(4*d*e*(1 - (Sqrt[e]*x)/Sqrt[-d])) - (a
+ b*ArcTan[c*x])^2/(4*d*e*(1 + (Sqrt[e]*x)/Sqrt[-d])) - (b*c*(a + b*ArcTan[c*x])*Log[(2*c*(Sqrt[-d] - Sqrt[e]*
x))/((c*Sqrt[-d] - I*Sqrt[e])*(1 - I*c*x))])/(2*Sqrt[-d]*(c^2*d - e)*Sqrt[e]) + (b*c*(a + b*ArcTan[c*x])*Log[(
2*c*(Sqrt[-d] + Sqrt[e]*x))/((c*Sqrt[-d] + I*Sqrt[e])*(1 - I*c*x))])/(2*Sqrt[-d]*(c^2*d - e)*Sqrt[e]) + ((I/4)
*b^2*c*PolyLog[2, 1 - (2*c*(Sqrt[-d] - Sqrt[e]*x))/((c*Sqrt[-d] - I*Sqrt[e])*(1 - I*c*x))])/(Sqrt[-d]*(c^2*d -
 e)*Sqrt[e]) - ((I/4)*b^2*c*PolyLog[2, 1 - (2*c*(Sqrt[-d] + Sqrt[e]*x))/((c*Sqrt[-d] + I*Sqrt[e])*(1 - I*c*x))
])/(Sqrt[-d]*(c^2*d - e)*Sqrt[e])

Rule 2315

Int[Log[(c_.)*(x_)]/((d_) + (e_.)*(x_)), x_Symbol] :> -Simp[PolyLog[2, 1 - c*x]/e, x] /; FreeQ[{c, d, e}, x] &
& EqQ[e + c*d, 0]

Rule 2402

Int[Log[(c_.)/((d_) + (e_.)*(x_))]/((f_) + (g_.)*(x_)^2), x_Symbol] :> -Dist[e/g, Subst[Int[Log[2*d*x]/(1 - 2*
d*x), x], x, 1/(d + e*x)], x] /; FreeQ[{c, d, e, f, g}, x] && EqQ[c, 2*d] && EqQ[e^2*f + d^2*g, 0]

Rule 2447

Int[Log[u_]*(Pq_)^(m_.), x_Symbol] :> With[{C = FullSimplify[(Pq^m*(1 - u))/D[u, x]]}, Simp[C*PolyLog[2, 1 - u
], x] /; FreeQ[C, x]] /; IntegerQ[m] && PolyQ[Pq, x] && RationalFunctionQ[u, x] && LeQ[RationalFunctionExponen
ts[u, x][[2]], Expon[Pq, x]]

Rule 4854

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)), x_Symbol] :> -Simp[((a + b*ArcTan[c*x])^p*Lo
g[2/(1 + (e*x)/d)])/e, x] + Dist[(b*c*p)/e, Int[((a + b*ArcTan[c*x])^(p - 1)*Log[2/(1 + (e*x)/d)])/(1 + c^2*x^
2), x], x] /; FreeQ[{a, b, c, d, e}, x] && IGtQ[p, 0] && EqQ[c^2*d^2 + e^2, 0]

Rule 4856

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))/((d_) + (e_.)*(x_)), x_Symbol] :> -Simp[((a + b*ArcTan[c*x])*Log[2/(1 -
 I*c*x)])/e, x] + (Dist[(b*c)/e, Int[Log[2/(1 - I*c*x)]/(1 + c^2*x^2), x], x] - Dist[(b*c)/e, Int[Log[(2*c*(d
+ e*x))/((c*d + I*e)*(1 - I*c*x))]/(1 + c^2*x^2), x], x] + Simp[((a + b*ArcTan[c*x])*Log[(2*c*(d + e*x))/((c*d
 + I*e)*(1 - I*c*x))])/e, x]) /; FreeQ[{a, b, c, d, e}, x] && NeQ[c^2*d^2 + e^2, 0]

Rule 4864

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_)*((d_) + (e_.)*(x_))^(q_.), x_Symbol] :> Simp[((d + e*x)^(q + 1)*(a
 + b*ArcTan[c*x])^p)/(e*(q + 1)), x] - Dist[(b*c*p)/(e*(q + 1)), Int[ExpandIntegrand[(a + b*ArcTan[c*x])^(p -
1), (d + e*x)^(q + 1)/(1 + c^2*x^2), x], x], x] /; FreeQ[{a, b, c, d, e}, x] && IGtQ[p, 1] && IntegerQ[q] && N
eQ[q, -1]

Rule 4884

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)^2), x_Symbol] :> Simp[(a + b*ArcTan[c*x])^(p +
 1)/(b*c*d*(p + 1)), x] /; FreeQ[{a, b, c, d, e, p}, x] && EqQ[e, c^2*d] && NeQ[p, -1]

Rule 4920

Int[(((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)*(x_))/((d_) + (e_.)*(x_)^2), x_Symbol] :> -Simp[(I*(a + b*ArcTan
[c*x])^(p + 1))/(b*e*(p + 1)), x] - Dist[1/(c*d), Int[(a + b*ArcTan[c*x])^p/(I - c*x), x], x] /; FreeQ[{a, b,
c, d, e}, x] && EqQ[e, c^2*d] && IGtQ[p, 0]

Rule 4978

Int[(((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)*(x_))/((d_) + (e_.)*(x_)^2)^2, x_Symbol] :> Dist[1/(4*d^2*Rt[-(e
/d), 2]), Int[(a + b*ArcTan[c*x])^p/(1 - Rt[-(e/d), 2]*x)^2, x], x] - Dist[1/(4*d^2*Rt[-(e/d), 2]), Int[(a + b
*ArcTan[c*x])^p/(1 + Rt[-(e/d), 2]*x)^2, x], x] /; FreeQ[{a, b, c, d, e}, x] && IGtQ[p, 0]

Rule 4984

Int[(((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)*((f_) + (g_.)*(x_))^(m_.))/((d_) + (e_.)*(x_)^2), x_Symbol] :> I
nt[ExpandIntegrand[(a + b*ArcTan[c*x])^p/(d + e*x^2), (f + g*x)^m, x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] &
& IGtQ[p, 0] && EqQ[e, c^2*d] && IGtQ[m, 0]

Rubi steps

\begin {align*} \int \frac {x \left (a+b \tan ^{-1}(c x)\right )^2}{\left (d+e x^2\right )^2} \, dx &=\frac {\int \frac {\left (a+b \tan ^{-1}(c x)\right )^2}{\left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )^2} \, dx}{4 (-d)^{3/2} \sqrt {e}}-\frac {\int \frac {\left (a+b \tan ^{-1}(c x)\right )^2}{\left (1+\frac {\sqrt {e} x}{\sqrt {-d}}\right )^2} \, dx}{4 (-d)^{3/2} \sqrt {e}}\\ &=-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1+\frac {\sqrt {e} x}{\sqrt {-d}}\right )}+\frac {(b c) \int \left (\frac {\sqrt {-d} e \left (a+b \tan ^{-1}(c x)\right )}{\left (c^2 d-e\right ) \left (-\sqrt {-d}+\sqrt {e} x\right )}+\frac {c^2 d \left (\sqrt {-d}+\sqrt {e} x\right ) \left (a+b \tan ^{-1}(c x)\right )}{\sqrt {-d} \left (c^2 d-e\right ) \left (1+c^2 x^2\right )}\right ) \, dx}{2 d e}+\frac {(b c) \int \left (\frac {\sqrt {-d} e \left (a+b \tan ^{-1}(c x)\right )}{\left (-c^2 d+e\right ) \left (\sqrt {-d}+\sqrt {e} x\right )}+\frac {c^2 \left (d+\sqrt {-d} \sqrt {e} x\right ) \left (a+b \tan ^{-1}(c x)\right )}{\left (c^2 d-e\right ) \left (1+c^2 x^2\right )}\right ) \, dx}{2 d e}\\ &=-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1+\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {(b c) \int \frac {a+b \tan ^{-1}(c x)}{-\sqrt {-d}+\sqrt {e} x} \, dx}{2 \sqrt {-d} \left (c^2 d-e\right )}+\frac {(b c) \int \frac {a+b \tan ^{-1}(c x)}{\sqrt {-d}+\sqrt {e} x} \, dx}{2 \sqrt {-d} \left (c^2 d-e\right )}+\frac {\left (b c^3\right ) \int \frac {\left (\sqrt {-d}+\sqrt {e} x\right ) \left (a+b \tan ^{-1}(c x)\right )}{1+c^2 x^2} \, dx}{2 \sqrt {-d} \left (c^2 d-e\right ) e}+\frac {\left (b c^3\right ) \int \frac {\left (d+\sqrt {-d} \sqrt {e} x\right ) \left (a+b \tan ^{-1}(c x)\right )}{1+c^2 x^2} \, dx}{2 d \left (c^2 d-e\right ) e}\\ &=-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1+\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{\left (c \sqrt {-d}-i \sqrt {e}\right ) (1-i c x)}\right )}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{\left (c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+\frac {\left (b c^3\right ) \int \left (\frac {\sqrt {-d} \left (a+b \tan ^{-1}(c x)\right )}{1+c^2 x^2}+\frac {\sqrt {e} x \left (a+b \tan ^{-1}(c x)\right )}{1+c^2 x^2}\right ) \, dx}{2 \sqrt {-d} \left (c^2 d-e\right ) e}+\frac {\left (b c^3\right ) \int \left (\frac {d \left (a+b \tan ^{-1}(c x)\right )}{1+c^2 x^2}+\frac {\sqrt {-d} \sqrt {e} x \left (a+b \tan ^{-1}(c x)\right )}{1+c^2 x^2}\right ) \, dx}{2 d \left (c^2 d-e\right ) e}+\frac {\left (b^2 c^2\right ) \int \frac {\log \left (\frac {2 c \left (-\sqrt {-d}+\sqrt {e} x\right )}{\left (-c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{1+c^2 x^2} \, dx}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}-\frac {\left (b^2 c^2\right ) \int \frac {\log \left (\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{\left (c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{1+c^2 x^2} \, dx}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}\\ &=-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1+\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{\left (c \sqrt {-d}-i \sqrt {e}\right ) (1-i c x)}\right )}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{\left (c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+\frac {i b^2 c \text {Li}_2\left (1-\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{\left (c \sqrt {-d}-i \sqrt {e}\right ) (1-i c x)}\right )}{4 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}-\frac {i b^2 c \text {Li}_2\left (1-\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{\left (c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{4 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+2 \frac {\left (b c^3\right ) \int \frac {a+b \tan ^{-1}(c x)}{1+c^2 x^2} \, dx}{2 \left (c^2 d-e\right ) e}\\ &=\frac {c^2 \left (a+b \tan ^{-1}(c x)\right )^2}{2 \left (c^2 d-e\right ) e}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1-\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {\left (a+b \tan ^{-1}(c x)\right )^2}{4 d e \left (1+\frac {\sqrt {e} x}{\sqrt {-d}}\right )}-\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{\left (c \sqrt {-d}-i \sqrt {e}\right ) (1-i c x)}\right )}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+\frac {b c \left (a+b \tan ^{-1}(c x)\right ) \log \left (\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{\left (c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{2 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}+\frac {i b^2 c \text {Li}_2\left (1-\frac {2 c \left (\sqrt {-d}-\sqrt {e} x\right )}{\left (c \sqrt {-d}-i \sqrt {e}\right ) (1-i c x)}\right )}{4 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}-\frac {i b^2 c \text {Li}_2\left (1-\frac {2 c \left (\sqrt {-d}+\sqrt {e} x\right )}{\left (c \sqrt {-d}+i \sqrt {e}\right ) (1-i c x)}\right )}{4 \sqrt {-d} \left (c^2 d-e\right ) \sqrt {e}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 8.88, size = 885, normalized size = 1.94 \[ -\frac {a^2}{2 e \left (e x^2+d\right )}+2 b c^2 \left (\frac {c \tan ^{-1}(c x)-\frac {\sqrt {e} \tan ^{-1}\left (\frac {\sqrt {e} x}{\sqrt {d}}\right )}{\sqrt {d}}}{2 e \left (c^3 d-c e\right )}-\frac {\tan ^{-1}(c x)}{2 e \left (e x^2 c^2+d c^2\right )}\right ) a+\frac {b^2 c^2 \left (\frac {4 \tan ^{-1}(c x)^2}{d c^2+e+\left (c^2 d-e\right ) \cos \left (2 \tan ^{-1}(c x)\right )}+\frac {4 \tan ^{-1}(c x) \tanh ^{-1}\left (\frac {\sqrt {-c^2 d e}}{c e x}\right )-2 \cos ^{-1}\left (-\frac {d c^2+e}{c^2 d-e}\right ) \tanh ^{-1}\left (\frac {c e x}{\sqrt {-c^2 d e}}\right )+\left (\cos ^{-1}\left (-\frac {d c^2+e}{c^2 d-e}\right )+2 i \tanh ^{-1}\left (\frac {c e x}{\sqrt {-c^2 d e}}\right )\right ) \log \left (\frac {2 c^2 d \left (\sqrt {-c^2 d e}-i e\right ) (c x-i)}{\left (c^2 d-e\right ) \left (d c^2+\sqrt {-c^2 d e} x c\right )}\right )+\left (\cos ^{-1}\left (-\frac {d c^2+e}{c^2 d-e}\right )-2 i \tanh ^{-1}\left (\frac {c e x}{\sqrt {-c^2 d e}}\right )\right ) \log \left (\frac {2 c^2 d \left (i e+\sqrt {-c^2 d e}\right ) (c x+i)}{\left (c^2 d-e\right ) \left (d c^2+\sqrt {-c^2 d e} x c\right )}\right )-\left (\cos ^{-1}\left (-\frac {d c^2+e}{c^2 d-e}\right )-2 i \left (\tanh ^{-1}\left (\frac {c d}{\sqrt {-c^2 d e} x}\right )+\tanh ^{-1}\left (\frac {c e x}{\sqrt {-c^2 d e}}\right )\right )\right ) \log \left (\frac {\sqrt {2} \sqrt {-c^2 d e} e^{-i \tan ^{-1}(c x)}}{\sqrt {c^2 d-e} \sqrt {d c^2+e+\left (c^2 d-e\right ) \cos \left (2 \tan ^{-1}(c x)\right )}}\right )-\left (\cos ^{-1}\left (-\frac {d c^2+e}{c^2 d-e}\right )+2 i \left (\tanh ^{-1}\left (\frac {c d}{\sqrt {-c^2 d e} x}\right )+\tanh ^{-1}\left (\frac {c e x}{\sqrt {-c^2 d e}}\right )\right )\right ) \log \left (\frac {\sqrt {2} \sqrt {-c^2 d e} e^{i \tan ^{-1}(c x)}}{\sqrt {c^2 d-e} \sqrt {d c^2+e+\left (c^2 d-e\right ) \cos \left (2 \tan ^{-1}(c x)\right )}}\right )-i \left (\text {Li}_2\left (\frac {\left (d c^2+e-2 i \sqrt {-c^2 d e}\right ) \left (c^2 d-c \sqrt {-c^2 d e} x\right )}{\left (c^2 d-e\right ) \left (d c^2+\sqrt {-c^2 d e} x c\right )}\right )-\text {Li}_2\left (\frac {\left (d c^2+e+2 i \sqrt {-c^2 d e}\right ) \left (c^2 d-c \sqrt {-c^2 d e} x\right )}{\left (c^2 d-e\right ) \left (d c^2+\sqrt {-c^2 d e} x c\right )}\right )\right )}{\sqrt {-c^2 d e}}\right )}{4 \left (c^2 d-e\right )} \]

Warning: Unable to verify antiderivative.

[In]

Integrate[(x*(a + b*ArcTan[c*x])^2)/(d + e*x^2)^2,x]

[Out]

-1/2*a^2/(e*(d + e*x^2)) + 2*a*b*c^2*(-1/2*ArcTan[c*x]/(e*(c^2*d + c^2*e*x^2)) + (c*ArcTan[c*x] - (Sqrt[e]*Arc
Tan[(Sqrt[e]*x)/Sqrt[d]])/Sqrt[d])/(2*e*(c^3*d - c*e))) + (b^2*c^2*((4*ArcTan[c*x]^2)/(c^2*d + e + (c^2*d - e)
*Cos[2*ArcTan[c*x]]) + (4*ArcTan[c*x]*ArcTanh[Sqrt[-(c^2*d*e)]/(c*e*x)] - 2*ArcCos[-((c^2*d + e)/(c^2*d - e))]
*ArcTanh[(c*e*x)/Sqrt[-(c^2*d*e)]] + (ArcCos[-((c^2*d + e)/(c^2*d - e))] + (2*I)*ArcTanh[(c*e*x)/Sqrt[-(c^2*d*
e)]])*Log[(2*c^2*d*((-I)*e + Sqrt[-(c^2*d*e)])*(-I + c*x))/((c^2*d - e)*(c^2*d + c*Sqrt[-(c^2*d*e)]*x))] + (Ar
cCos[-((c^2*d + e)/(c^2*d - e))] - (2*I)*ArcTanh[(c*e*x)/Sqrt[-(c^2*d*e)]])*Log[(2*c^2*d*(I*e + Sqrt[-(c^2*d*e
)])*(I + c*x))/((c^2*d - e)*(c^2*d + c*Sqrt[-(c^2*d*e)]*x))] - (ArcCos[-((c^2*d + e)/(c^2*d - e))] - (2*I)*(Ar
cTanh[(c*d)/(Sqrt[-(c^2*d*e)]*x)] + ArcTanh[(c*e*x)/Sqrt[-(c^2*d*e)]]))*Log[(Sqrt[2]*Sqrt[-(c^2*d*e)])/(Sqrt[c
^2*d - e]*E^(I*ArcTan[c*x])*Sqrt[c^2*d + e + (c^2*d - e)*Cos[2*ArcTan[c*x]]])] - (ArcCos[-((c^2*d + e)/(c^2*d
- e))] + (2*I)*(ArcTanh[(c*d)/(Sqrt[-(c^2*d*e)]*x)] + ArcTanh[(c*e*x)/Sqrt[-(c^2*d*e)]]))*Log[(Sqrt[2]*Sqrt[-(
c^2*d*e)]*E^(I*ArcTan[c*x]))/(Sqrt[c^2*d - e]*Sqrt[c^2*d + e + (c^2*d - e)*Cos[2*ArcTan[c*x]]])] - I*(PolyLog[
2, ((c^2*d + e - (2*I)*Sqrt[-(c^2*d*e)])*(c^2*d - c*Sqrt[-(c^2*d*e)]*x))/((c^2*d - e)*(c^2*d + c*Sqrt[-(c^2*d*
e)]*x))] - PolyLog[2, ((c^2*d + e + (2*I)*Sqrt[-(c^2*d*e)])*(c^2*d - c*Sqrt[-(c^2*d*e)]*x))/((c^2*d - e)*(c^2*
d + c*Sqrt[-(c^2*d*e)]*x))]))/Sqrt[-(c^2*d*e)]))/(4*(c^2*d - e))

________________________________________________________________________________________

fricas [F]  time = 0.43, size = 0, normalized size = 0.00 \[ {\rm integral}\left (\frac {b^{2} x \arctan \left (c x\right )^{2} + 2 \, a b x \arctan \left (c x\right ) + a^{2} x}{e^{2} x^{4} + 2 \, d e x^{2} + d^{2}}, x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arctan(c*x))^2/(e*x^2+d)^2,x, algorithm="fricas")

[Out]

integral((b^2*x*arctan(c*x)^2 + 2*a*b*x*arctan(c*x) + a^2*x)/(e^2*x^4 + 2*d*e*x^2 + d^2), x)

________________________________________________________________________________________

giac [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arctan(c*x))^2/(e*x^2+d)^2,x, algorithm="giac")

[Out]

Timed out

________________________________________________________________________________________

maple [B]  time = 1.05, size = 1185, normalized size = 2.59 \[ \text {result too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x*(a+b*arctan(c*x))^2/(e*x^2+d)^2,x)

[Out]

-1/2*c^2*a^2/e/(c^2*e*x^2+c^2*d)-1/2*c^2*b^2/e/(c^2*e*x^2+c^2*d)*arctan(c*x)^2+1/2*b^2/e*(c^2*e*d)^(1/2)/d/(c^
2*d-e)*arctan(c*x)^2+I*c^2*b^2*ln(1-(c^2*d-e)*(1+I*c*x)^2/(c^2*x^2+1)/(-c^2*d-2*(c^2*e*d)^(1/2)-e))*arctan(c*x
)/(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*(c^2*e*d)^(1/2)-1/2*I*c^4*b^2/e*ln(1-(c^2*d-e)*(1+I*c*x)^2/(c^2*x^2+1)/(-c
^2*d-2*(c^2*e*d)^(1/2)-e))*arctan(c*x)/(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*(c^2*e*d)^(1/2)*d+1/2*I*b^2/e*(c^2*e*
d)^(1/2)/d/(c^2*d-e)*arctan(c*x)*ln(1-(c^2*d-e)*(1+I*c*x)^2/(c^2*x^2+1)/(-c^2*d+2*(c^2*e*d)^(1/2)-e))+c^2*b^2/
(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*arctan(c*x)^2*(c^2*e*d)^(1/2)+1/2*c^2*b^2/(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*
polylog(2,(c^2*d-e)*(1+I*c*x)^2/(c^2*x^2+1)/(-c^2*d-2*(c^2*e*d)^(1/2)-e))*(c^2*e*d)^(1/2)-1/2*I*b^2*e*ln(1-(c^
2*d-e)*(1+I*c*x)^2/(c^2*x^2+1)/(-c^2*d-2*(c^2*e*d)^(1/2)-e))*arctan(c*x)/(c^2*d-e)/d/(c^4*d^2-2*c^2*d*e+e^2)*(
c^2*e*d)^(1/2)+1/2*c^2*b^2/e*arctan(c*x)^2/(c^2*d-e)+1/4*b^2/e*(c^2*e*d)^(1/2)/d/(c^2*d-e)*polylog(2,(c^2*d-e)
*(1+I*c*x)^2/(c^2*x^2+1)/(-c^2*d+2*(c^2*e*d)^(1/2)-e))-1/2*b^2*e/d/(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*arctan(c*
x)^2*(c^2*e*d)^(1/2)-1/4*b^2*e/d/(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*polylog(2,(c^2*d-e)*(1+I*c*x)^2/(c^2*x^2+1)
/(-c^2*d-2*(c^2*e*d)^(1/2)-e))*(c^2*e*d)^(1/2)-1/4*c^4*b^2/e/(c^2*d-e)/(c^4*d^2-2*c^2*d*e+e^2)*polylog(2,(c^2*
d-e)*(1+I*c*x)^2/(c^2*x^2+1)/(-c^2*d-2*(c^2*e*d)^(1/2)-e))*(c^2*e*d)^(1/2)*d-1/2*c^4*b^2/e/(c^2*d-e)/(c^4*d^2-
2*c^2*d*e+e^2)*arctan(c*x)^2*(c^2*e*d)^(1/2)*d-c^2*a*b/e/(c^2*e*x^2+c^2*d)*arctan(c*x)-c*a*b/(c^2*d-e)/(d*e)^(
1/2)*arctan(e*x/(d*e)^(1/2))+c^2*a*b/e/(c^2*d-e)*arctan(c*x)

________________________________________________________________________________________

maxima [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*arctan(c*x))^2/(e*x^2+d)^2,x, algorithm="maxima")

[Out]

Timed out

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.00 \[ \int \frac {x\,{\left (a+b\,\mathrm {atan}\left (c\,x\right )\right )}^2}{{\left (e\,x^2+d\right )}^2} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((x*(a + b*atan(c*x))^2)/(d + e*x^2)^2,x)

[Out]

int((x*(a + b*atan(c*x))^2)/(d + e*x^2)^2, x)

________________________________________________________________________________________

sympy [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x*(a+b*atan(c*x))**2/(e*x**2+d)**2,x)

[Out]

Timed out

________________________________________________________________________________________